package com.es.www.customAop;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import com.es.www.customAop.service.CatService;

/**
 * @Created by michangtao
 * @Date 2022/2/10 17:17
 * @Description
 */
@Configuration
@ComponentScan("com.es.www.customAop")
public class CustomAopApplication {

    public static void main(String[] args) {
        AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(CustomAopApplication.class);
        CatService catService = ctx.getBean(CatService.class);
        catService.eat("鱼");
    }
}
